package com.qf.proxy.staticproxy.demo1;

/**
 * @author lwc
 * @date 2021/10/27 11:29
 * @Description
 */
public class Tenant {

    public static void main(String[] args) {
        Tenant tenant = new Tenant();
        tenant.tenantHouse();
    }
    //租客租房的方法
    private void  tenantHouse(){
        //真实对象
        HouseOwner houseOwner = new HouseOwner();
        //代理对象
        Intermediary intermediary = new Intermediary(houseOwner);
        //调用代理对象中方法
        intermediary.rent();
    }

}
